package cn.javass.dp.decorator.example1;

public class ConcreteBDecoratorA extends Decorator{
    public ConcreteBDecoratorA(Component component) {
        super(component);
    }

    private String addedState;

    public String getAddedState() {
        return addedState;
    }

    public void setAddedState(String addedState) {
        this.addedState = addedState;
    }

    @Override
    public void operation() {
        //调用父类方法，可以在调用前后添加一些附加操作
        System.out.println("begin。。。。");
        super.operation();

    }
}
